package com.iot08.common.entity.app;

import com.alibaba.fastjson.JSONObject;
import lombok.Data;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.Field;

import java.io.Serializable;
import java.util.Date;

/**
 * 课程表
 * @author weichao 1299101858@qq.com
 * @version 1.0
 * @date 4/28/22 3:39 PM
 */
@Data
@Document("school_timetable")
public class SchoolTimetable implements Serializable {
    private static final long serialVersionUID = 1L;
    /*
    {
        "morningBreakTime": "11:10",    [str] //上午下课时间
        "afternoonBreakTime": "16:35",  [str] //下午下课时间
        "classTimesInfo": {     [dict]  //课程的时间段 信息Map
            "1": "08:45-09:25",     [srt]   // key:第几节     value 课程的时间段
            "3": "10:30—11:10",
            "2": "09:35—10:15",
            "5": "15:05—15:45",
            "4": "14:10—14:50",
            "6": "15:55—16:35"
        },
        "coursesInfoDict": {    [dict]  //具体的课程位置 和 课程信息
            "3&2": {            [dict]  //key 周几 第几节 的坐标 value 课程的信息(名称,描述等...(可扩展))
                "des": "英语课的说明",
                "name": "英语课"
            },
            "3&3": {
                "des": "语文课的说明",
                "name": "语文课"
            }
        }
    }
     */
    @Field("_id")
    private String id;

    private String morningBreakTime = "";

    private String afternoonBreakTime = "";

    private JSONObject classTimesInfo = new JSONObject();

    private JSONObject coursesInfoDict = new JSONObject();

    //操作者openid
    private String operatorId;
    //更新时间
    private Date changeTime;

}
